
<!DOCTYPE html>
<html>

<head>
    <title>Demo</title>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
    <meta name="format-detection" content="tephone=no,email=no,date=no,address=no">
    <!-- 1.7.1/1.11.1/2.1.1 -->
    <script type="text/javascript" src="http://space.cdn.ports-intl.com/Ports/Ports-intl/common/Lib/jQuery/Lib/jquery-1.7.1.min.js"></script>
    <!-- Latest compiled and minified CSS -->
    <link rel="stylesheet" href="http://space.cdn.ports-intl.com/Ports/Ports-intl/common/Lib/h5style/css/import-min.css">
    <link rel="stylesheet" type="text/css" href="api.css">
    <style type="text/css">
    html {
        background-color: white;
    }
    
    span {
        padding: 10px 15px;
        margin: 10px;
        display: inline-block;
        background-color: #e8e8e8;
    }
    
    .hover {
        opacity: .4;
    }
    </style>
</head>

<body>
    <div class="container-fluid">
        <div class="row">
            <div class="col-xs-6">
                <br><br><br>
                <center><button type="button" class="btn btn-info" onclick="OpenWind11();">艾美荟服务器版</</button></center>
                <br><br><br>
                <center><button type="button" class="btn btn-info" onclick="OpenWind22();">艾美荟本地测试版</button></center>
            </div>
        </div>
    </div>
    <script type="text/javascript">
    function OpenP1() {
        api.openFrame({
            name: 'page2',
            url: '/ApiCloud/p1.html',
            rect: {
                x: 0,
                y: 0,
                w: 320,
                h: 480
            },
            pageParam: {
                name: 'test'
            },
            animation: {
                // type: 'push'
                type: "push", //动画类型（详见动画类型常量）
                subType: "from_right", //动画子类型（详见动画子类型常量）
                duration: 400 //动画过渡时间，默认300毫秒
            },
            bounces: true,
            bgColor: '#FFF',
            vScrollBarEnabled: false,
            hScrollBarEnabled: false
        });
    }

    function OpenWind() {
        api.openWin({
            name: 'page2',
            url: '/ApiCloud/p2.html?v=1',
            pageParam: {
                name: 'test'
            },
            bgColor: '#f00',
            animation: {
                // type: 'push'
                type: "movein", //动画类型（详见动画类型常量）
                subType: "from_right", //动画子类型（详见动画子类型常量）
                duration: 400 //动画过渡时间，默认300毫秒
            },
            delay: 1000,
            showProgress: true,
            slidBackEnabled: true
        });
    }

    function OpenWind22() {
        api.openWin({
            name: 'page3',
            url: 'http://meiye.hj.cpax.cn/MobileApp/device',
            pageParam: {
                name: 'test'
            },
            bgColor: '#f00',
            animation: {
                // type: 'push'
                type: "movein", //动画类型（详见动画类型常量）
                subType: "from_right", //动画子类型（详见动画子类型常量）
                duration: 400 //动画过渡时间，默认300毫秒
            },
            delay: 1000,
            showProgress: true,
            slidBackEnabled: true
        });
    }
    function OpenWind11() {
        api.openWin({
            name: 'page3',
            url: 'http://aliyun03.hjie.net:9080/MobileApp/device',
            pageParam: {
                name: 'test'
            },
            bgColor: '#f00',
            animation: {
                // type: 'push'
                type: "movein", //动画类型（详见动画类型常量）
                subType: "from_right", //动画子类型（详见动画子类型常量）
                duration: 400 //动画过渡时间，默认300毫秒
            },
            delay: 1000,
            showProgress: true,
            slidBackEnabled: true
        });
    }
    </script>
</body>

</html>
